package com.sc.nft.dao;

import com.sc.nft.entity.DaoAccountBankInfo;
import lombok.extern.slf4j.Slf4j;
import com.sc.nft.entity.DaoAccountLegalPerson;
import com.sc.nft.mapper.DaoAccountLegalPersonMapper;
import  com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Repository;

/**
 * (sc_dao_account_legal_person)数据DAO
 *
 * @author zxy
 * @since 2023-11-25 16:18:38
 * @description 商户banner
 */
@Slf4j
@Repository
public class DaoAccountLegalPersonDao extends ServiceImpl<DaoAccountLegalPersonMapper, DaoAccountLegalPerson> {

    public void clearByAccountId(Long accountId){
        lambdaUpdate().eq(DaoAccountLegalPerson::getDaoOpenAccountId,accountId).remove();
    }

    public DaoAccountLegalPerson getByAccountId(Long accountId){
        return lambdaQuery().eq(DaoAccountLegalPerson::getDaoOpenAccountId,accountId).one();
    }
}